nfsd: fix legacy client tracking initialization
authorScott Mayhew <smayhew@redhat.com>
Tue, 10 Dec 2024 12:25:54 +0000 (07:25 -0500)
committerSalvatore Bonaccorso <carnil@debian.org>
Sun, 23 Mar 2025 13:34:08 +0000 (14:34 +0100)
commit801a85f4214a4e75e3f96dee5c9ca7f461f8a687
treec49f42417b6075f4cc9b1ac2f77cbe641209c6a5
parent38b1f5db55007e6dba0721be2c295a7c293ac1e9
nfsd: fix legacy client tracking initialization

Origin: https://git.kernel.org/pub/scm/linux/kernel/git/cel/linux.git/commit/?h=nfsd-next&id=45cd8c0c13fe5c9f1b926bd307df431f8f1b8a16
Bug: https://bugzilla.kernel.org/show_bug.cgi?id=219580
Bug-Debian: https://bugs.debian.org/1087900

Get rid of the nfsd4_legacy_tracking_ops->init() call in
check_for_legacy_methods().  That will be handled in the caller
(nfsd4_client_tracking_init()).  Otherwise, we'll wind up calling
nfsd4_legacy_tracking_ops->init() twice, and the second time we'll
trigger the BUG_ON() in nfsd4_init_recdir().

Fixes: 74fd48739d04 ("nfsd: new Kconfig option for legacy client tracking")
Reported-by: Jur van der Burg <jur@avtware.com>
Link: https://bugzilla.kernel.org/show_bug.cgi?id=219580
Signed-off-by: Scott Mayhew <smayhew@redhat.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Gbp-Pq: Topic bugfix/all
Gbp-Pq: Name nfsd-fix-legacy-client-tracking-initialization.patch
fs/nfsd/nfs4recover.c